package com.dms.modules.user.dto;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.Email;
import javax.validation.constraints.Pattern;

@Data
@ApiModel(value = "UserProfileDTO对象", description = "用户资料")
public class UserProfileDTO {
    
    @ApiModelProperty("用户ID")
    private Long id;
    
    @ApiModelProperty("昵称")
    private String nickname;
    
    @ApiModelProperty("头像URL")
    private String avatar;
    
    @ApiModelProperty("性别：0-未知，1-男，2-女")
    private Integer gender;
    
    @ApiModelProperty("生日")
    private String birthday;
    
    @ApiModelProperty("手机号")
    @Pattern(regexp = "^1[3-9]\\d{9}$", message = "手机号格式不正确")
    private String phone;
    
    @ApiModelProperty("邮箱")
    @Email(message = "邮箱格式不正确")
    private String email;
    
    @ApiModelProperty("个性签名")
    private String signature;
    
    @ApiModelProperty("个人简介")
    private String bio;
    
    @ApiModelProperty("角色ID：1-管理员 2-商家 3-用户")
    private Long roleId;
    
    @ApiModelProperty("状态：0-禁用 1-正常")
    private Integer status;
} 